<?php

use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;

class CreateProductUrlTypesTable extends Migration {

	/**
	 * Run the migrations.
	 *
	 * @return void
	 */
	public function up()
	{
		Schema::create('product_url_types', function(Blueprint $table)
		{
			$table->integer('id', true)->comment('网站的类型名称');
			$table->string('name', 50)->comment('网站的名称');
			$table->string('const', 50)->comment('名称的常量值');
			$table->string('type_icon')->nullable()->comment('商品平台的图标');
			$table->string('qrcode_icon')->nullable()->comment('商品平台二维码的图标');
			$table->integer('priority')->default(0)->comment('优先级，由大到小');
			$table->timestamps();
		});
	}


	/**
	 * Reverse the migrations.
	 *
	 * @return void
	 */
	public function down()
	{
		Schema::drop('product_url_types');
	}

}
